Show Posts
|
|
Pages: 1 2 [3] 4 5 ... 17
|
|
32
|
Products / Arduino Due / Re: Arduino Due - Serial speed?
|
on: December 14, 2012, 06:22:02 am
|
Hello Paul, Again I insist, the download time is 10x Here are some threads dealing with I think a more global issue related to Programmer USB port, in my case, I use MacBook Air where my code has been running for years on mega, it is Serial protocol using HDLC on to of USB. http://arduino.cc/forum/index.php/topic,134847http://arduino.cc/forum/index.php/topic,135011http://arduino.cc/forum/index.php/topic,135095P.S. My arduino DUE is not a beta, just bought in belgium recently at antratek company Albert
|
|
|
|
|
34
|
Products / Arduino Due / Re: Arduino Due - Serial speed?
|
on: December 12, 2012, 11:05:20 pm
|
|
On some other recent threads, it is clearly observed that the Serial USB link wether HW or SW (low level or high level) have serious speed issue. One way to perceive this, there are many other methods and practical tests, is by observing the same *.INO project loaded on mega takes almost no time to USB download but HUGE time to download on DUE.
|
|
|
|
|
35
|
Products / Arduino Due / Re: Garbage using serial functions in Arduino Due
|
on: December 02, 2012, 10:49:34 pm
|
P.S. Another thing that I've noticed, maybe i'm not doing something right with IDE but i've noticed two differences between same code compile/load on MEGA versus on DUE: - both compilation times seem similar
- downloading into DUE takes more than 10 or 20 times than downloading into MEGA
Do you think this could be related to the same issue we're discussing here ?
|
|
|
|
|
36
|
Products / Arduino Due / Re: Garbage using serial functions in Arduino Due
|
on: December 02, 2012, 01:20:57 pm
|
|
In my case, it happens at 112500 bauds. I could change easily my software which consist to make dialog a Java GUI on MacBook Air with my Mega or my Due but i don't feel loosing anymore time on this since it is obvious in this thread or other recent related threads the Serial.libs function in 1.5 IDE are the root cause of this issue... Sorry !
|
|
|
|
|
37
|
Products / Arduino Due / Re: SerialEvent() wont work
|
on: December 02, 2012, 11:08:58 am
|
|
Hi fat16lib,
I'm bit lost, not sure to understand your last post, have you found a fix or would it better waiting for another IDE release or fix directly from arduino team ?
In my case where I'm porting a big arduino mega project into arduino due, i need to use different Serial functions, not only Serial.begin(baud_rate), Serial.available() and Serial.read() but also functions like Serial.write() and Serial.flush()
Thank you in advance, Albert
|
|
|
|
|
38
|
Products / Arduino Due / Re: SerialEvent() wont work
|
on: December 02, 2012, 07:12:58 am
|
|
OK I've replaced all occurrence such as INT or UNSIGNED INT by int16_t and uint16_t as found in my MEGA running SerPro protocol so it will more portable. Runs fine with my MEGA board but still fails with DUE even though compiles & downloads OK on DUE.
Unless I make an error, it is obvious to me that the Serial functionS set or family (i.e. read(), write(), event(),...) do not work on DUE if called inside an IDE, at least at 115200 bauds !
|
|
|
|
|
39
|
Products / Arduino Due / Re: Garbage using serial functions in Arduino Due
|
on: December 01, 2012, 10:36:25 am
|
I'm almost convinced there is something wrong with DUE's implementation of Serial.available() Serial.read() and so As I've explained on some other threads this morning, I've got code running for years on MEGA, it does compile the download fine on DUE but will not work, in my case a Serial protocol called SerPro using HDLC on top of USB link. There are constant CRC errors hence the frames are rejected then re-sent, my core program // Start of SERPRO implementation struct SerialWrapper { public: static inline void write(uint8_t v){Serial.write(v);} static inline void write(const uint8_t *buf,int size){ int z; for(z=0;z<size;z++) Serial.write(buf[z]); } static inline void flush() {} };
struct SerProConfig { static unsigned int const maxFunctions = MAX_SERPRO_FUNCTIONS; static unsigned int const maxPacketSize = 32; static unsigned int const stationId = 3; static SerProImplementationType const implementationType = Slave; };
DECLARE_SERPRO(SerProConfig,SerialWrapper,SerProHDLC,SerPro);
void setup() { // protocol initialization Serial.begin(BAUD_RATE);
// Testing leds pinMode(ledLinkUp,OUTPUT); pinMode(ledCRCerror,OUTPUT); pinMode(ledRcv,OUTPUT); pinMode(ledXmit,OUTPUT); }
void loop() { if (Serial.available() > 0) SerPro::processData(Serial.read() & 0xff); }
// End of SERPRO implementation IMPLEMENT_SERPRO(MAX_SERPRO_FUNCTIONS,SerPro,SerProHDLC);
|
|
|
|
|
40
|
Products / Arduino Due / Re: Porting MEGA to DUE - Guidelines
|
on: December 01, 2012, 07:20:56 am
|
P.S. Another thing that I've noticed, maybe i'm not doing something right with IDE but i've noticed two differences between same code compile/load on MEGA versus on DUE: - both compilation times seem similar
- downloading into DUE takes more than 10 or 20 times than downloading into MEGA
Thank you for any sharing, help, suggestions...
|
|
|
|
|
41
|
Products / Arduino Due / Porting MEGA to DUE - Guidelines
|
on: December 01, 2012, 05:19:21 am
|
|
Hello,
The question I have here, what should be the guidelines or key steps, checkings, headers added, modifications to insure that an IDE fully running and operational on MEGA board will work right away on DUE...
It would be interesting to have reports on how MEGA code ports easy or what has to be done so it ports in DUE without big work.
In my case, I'm struggling probably through the same issue where i've been using SerPro protocol open sourced by Alvaro known member of arduino forum, it has been working for more than 2 years within different MEGA (1280, 2560 rev 2 and rev 3) on different projects. When It will work OK then download on DUE but the SerPro protocol using Serial standard routines does not work. Please note that SerPro is an implementation HDLC on top of USB protocol plus has object oriented programming to add very easy any RX or TX commands coming from a GUI (Mac, PC or Linux) so among other things, has 16-bit CRC detection.
Another aspect that might explain the problem, do some of you have been confronted to a endianness issue between MEGA, in fact all classic arduino AVR boards and DUE since we go from 8-bits to 32-bits. I've noticed the DUE compiler did check mistake when using INT on AVR so 16bits but if we leave this on DUE, it thinks of 32-bits or something else.
Albert
|
|
|
|
|
42
|
Products / Arduino Due / Re: SerialEvent() wont work
|
on: December 01, 2012, 02:52:52 am
|
|
Another aspect that might explain the problem, do some of you have been confronted to a endianness issue between MEGA, in fact all classic arduino AVR boards and DUE since we go from 8-bits to 32-bits. I've noticed the DUE compiler did check mistake when using INT on AVR so 16bits but if we leave this on DUE, it thinks of 32-bits or something else.
|
|
|
|
|
43
|
Products / Arduino Due / Serial routines MEGA versus DUE
|
on: December 01, 2012, 12:49:52 am
|
|
I'm struggling probably through the same issue where i've been using SerPro protocol open sourced by Alvaro, it has been working for more than 2 years within different MEGA (1280, 2560 rev 2 and rev 3) on different projects. When It will work OK then download on DUE but the SerPro protocol using Serial standard routines does not work. Please note that SerPro is an implementation HDLC on top of USB protocol plus has object oriented programming to add very easy any RX or TX commands coming from a GUI (Mac, PC or Linux) so among other things, has 16-bit CRC detection.
|
|
|
|
|
44
|
Using Arduino / Installation & Troubleshooting / Re: Timer Interrupt Capture ICP
|
on: April 16, 2012, 11:18:46 pm
|
|
On a side note, i've noticed also upon viewing arduino mega schematics that it is not possible to generate ICP1 via ACO (Analog Comparator Output) making specific use of AIN0 and AIN1 pins input !
So yes, arduino mega can only manage ICP4 and ICP5 hence use only timer4 and timer5 as time stamper, data logger, PWM duty cycle or PWM frequency estimate...
|
|
|
|
|