Forum

Welcome Guest 

Show/Hide Header

Welcome Guest, posting in this forum requires registration.





Pages: [1]
Author Topic: Can we write on SD card from serial?
EATYone
Advanced
Posts: 67
Permalink
Post Can we write on SD card from serial?
on: August 23, 2016, 17:07
Quote

Do u think it's possible to write queue txt files from serial port to SD card?

sandy
Administrator
Posts: 1317
Permalink
sandy
Post Re: Can we write on SD card from serial?
on: August 24, 2016, 18:44
Quote

Yes, on the "queue" tab, click "signal store", and enter a filename. From that point until you click "signal play" (or reset the machine), commands will be written to the filename rather than executed directly.

I'll be honest, I've used this about twice, ever, and it was years ago, so I've no idea if it still works. Give it a shot?

sn

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 11:12
Quote

will try it this afternoon 🙂

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 12:51
Quote

Seems to be ok, and a really cool option. Need that because i replace usb cable by a little bluetooth module, and don't want let my laptop on during drawing. S like you say : signal store ---> signal play ---> exec from store ... except some command not parsed (seems that i've got a transmission pb), all is ok. Really cool, will look at your code for that... And try to find a solution for not parsed comm ... Can i reduce the Bauds for serial com or make it faster than 57600?

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 12:54
Quote

all is ok with usb, but i want to find why i've got pb by bluetooth...

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 12:58
Quote

...
Image

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 15:34
Quote

same things @ 115200 ... Will try to decrease, but since i've read some google answers to my problem, it seem's it's not a baudrate problem ... but i can't understand the pb.... sad 🙁

sandy
Administrator
Posts: 1317
Permalink
sandy
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 18:39
Quote

I never found baudrate to make any kind of speed difference at all.

That message "Comm () not parsed" isn't necessarily something to fix. What it means (if I remember right) is that there's been a "command terminated" character received (ascii 10 - Line Feed LF - https://github.com/euphy/polargraph_server_polarshield/blob/master/polargraph_server_polarshield.ino#L183), but that when it tried to process the command that was terminated, there wasn't actually anything there.

So that happens when you send a ascii 10 without any preceding commands. The command would show up in the parentheses if it really had been received.

I can't quite remember, but it rings a bell - when I was dabbling in zigbee networks, there were spurious CR and LF commands that the wireless comms inserted. At the time, the protocol was a lot more fragile, and it caused chaos. Now it should have no effect.

sn

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 21:05
Quote

yes remember too Xbee some years ago with and first Dualminove 🙂 Will check the txt file... But when i print draw in realtime some C14 and C13 are forgot ...

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 21:06
Quote

Anyway, thnx to read and answer to those messages :):):)

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 21:10
Quote

Like i said, pb with some C13 and C14 .... And perhaps with some C17 but can't see by eyes... I've to found a soft to compare data file...
Image
Image

EATYone
Advanced
Posts: 67
Permalink
Post Re: Can we write on SD card from serial?
on: August 25, 2016, 21:53
Quote

will try another BT module tomorrow...

Nicolredma-
y
Newbie
Posts: 1
Permalink
Post Re: Can we write on SD card from serial?
on: December 6, 2016, 09:19
Quote

Hi,

yeah I was able to create a file with the bellow mentioned code in tmp folder

#include <iostream>

#include <fstream>

#include <string>

using namespace std;

string filename = "/tmp/filename.txt";

int main() {

std::ofstream o(filename.c_str());

o << "Hello, World\n" << std::endl;

return 0;

}

So that means we can create text file other then SD card.

Pages: [1]
Mingle Forum by cartpauj
Version: 1.0.34 ; Page loaded in: 0.042 seconds.