Comments (10)
One other thing to try if you haven't already is to delay a couple of seconds after startup of your client application before sending the I2C_WRITE command. I'm wondering if the issue could be related to the Firmata blink sequence (series of delays) running at startup.
from arduino.
You may be using an i2c device that needs an auto restart at the end of the transmission (Wire.endTransmission(false)
). See this issue: #82.
I have a pull request open to add this functionality. Try the i2c-restart
branch and let me know if that solves the issue for you. Check the addendum to the i2c implementation here to see what you'll need to change in your Firmata client. Note bit 6 of byte 3 (restartTx) set this to 1.
from arduino.
What is the current default of arduino 1.0.5 endTransmission when nothing
is supplied? Im not doing anything in my sketch:
Wire.beginTransmission(LEDAddress);
Wire.write(DISP_CHAR_5X7);
Wire.write(data_);
Wire.write(time>>8); //high byte of time
Wire.write(time);//low byte of time
Wire.endTransmission();
On Mon, Nov 18, 2013 at 5:30 PM, Jeff Hoefs [email protected]:
You may be using an i2c device that needs an auto restart at the end of
the transmission (Wire.endTransmission(false)). See this issue: #82#82
.I have a pull request #92 open
to add this functionality. Try the i2c-restart branch and let me know if
that solves the issue for you. Check the addendum to the i2c implementation
here https://github.com/firmata/protocol/blob/master/i2c.md to see what
you'll need to change in your Firmata client. Note bit 6 of byte 3
(restartTx) set this to 1.—
Reply to this email directly or view it on GitHubhttps://github.com//issues/101#issuecomment-28754950
.
from arduino.
No parameter to endTransmission()
is default so in your arduino example above that is using the default. And you have no issues running that code directly on an Arduino, you only have the issue with Firmata, correct?
from arduino.
Correct
On Mon, Nov 18, 2013 at 7:41 PM, Jeff Hoefs [email protected]:
running
from arduino.
and in your client code yours sending an I2C_CONFIG message to set up the pins, then your sending an I2C_WRITE message?
from arduino.
Do you have any other i2c devices you can test with? I have used the following with Firmata successfully:
blinkM rgb led
ITG3200 gyro
HMC6352 digital compass
ADXL345 accelerometer
HMC5883 magnetometer
from arduino.
I have a few more things Ill be testing next.
Yes Im configuring. Not that you know my under the hood implementation, but
this is the same code in my ios implementation:
[currentFirmata i2cConfig:0 data:[[NSData alloc]init]];
#define DISP_CHAR_5X7 0x80
#define LEDAddress 0x04
int time = 10000;
const unsigned char led[] = {DISP_CHAR_5X7, 'n', time>>8, time & 0xff};
NSData *data = [[NSData alloc] initWithBytes:led length:sizeof(led)];
[currentFirmata i2cRequest:WRITE address:LEDAddress data:data];
[currentFirmata i2cRequest:WRITE address:LEDAddress data:data];
Again, second call and all subsequent i2crequest calls work.
On Mon, Nov 18, 2013 at 8:44 PM, Jeff Hoefs [email protected]:
Do you have any other i2c devices you can test with? I have used the
following with Firmata successfully:blinkM rgb led
ITG3200 gyro
HMC6352 digital compass
ADXL345 accelerometer
HMC5883 magnetometer—
Reply to this email directly or view it on GitHubhttps://github.com//issues/101#issuecomment-28762874
.
from arduino.
please see this issue: #102. I'm pretty sure this is the same thing you brought up on the dev list. Please any additional thoughts you may have.
from arduino.
@jacobrosenthal do you still notice this behavior at all?
from arduino.
Related Issues (20)
- Analog pin as digital. HOT 3
- Analog Pins on Constant Voltage HOT 1
- Additional Firmata Java library
- Inconsistent state for additional analog pins (A6 - A11) on Arduino Leonardo HOT 1
- Pyfirmata and arduino leonardo mouse and keyboard abilities HOT 2
- T HOT 1
- Error compiling for board Arduino Uno. HOT 1
- Error compiling Firmata for board Arduino Nano Every HOT 8
- Error when compiling StandardFirmata 2.5.8 for Ardbox Analog HF + Wifi from Industrialshields HOT 2
- broken link in readme.md
- Last released version is from 2018 despite a lot of new work being merged HOT 10
- How to change TX RX pin for Nano HOT 3
- To drive a Servo what Capabilities do i need from a board? HOT 2
- Ethernet server mode versus client mode HOT 1
- Arduino HOT 1
- Arduino Nano Every doesn't report A6 and A7 on StandardFirmata HOT 3
- add Arduino UNO R4 MINIMA to boards.h please HOT 11
- [Question] How to add support for Jolly-dev to StandardFirmataWiFi HOT 9
- Firmata for Raspberry Pi Pico HOT 1
- Problem compiling firmata for Giga R1 Wifi board HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arduino.