BV4221 Stopped Working
September 13, 2013 03:30PM
I've been working with a BV4221 to read and write to a I2C device, initially using BV-Com which worked fine and I've just started writing some VB code.

All was going well until I tried to write a 255 byte block of data when it all locked up. After a reset it doesn't appear to function as before. It appears as a com port but I can't get the 0x42> prompt anymore. The three chip select lines flash on reset.

Is it possible I've managed to overwrite the firmware on the board somehow? Is there any way of checking and can I reprogram it?

Any help would be much appreciated.


Re: BV4221 Stopped Working
September 13, 2013 03:40PM
The BV4221_V2 has a buffer limit 70 and so it is likely that it has wrapped round when sending more bytes than it is capable of receiving.

It is not really possible to write to flash from the user interface so it is probable that the settings have been altered to suppress the prompt, try P1

This device can be upgraded via the USB so if all else fails the firmware can be reloaded via the built in boot loader.

The latest firmware and instructions are on This page.
Re: BV4221 Stopped Working
September 16, 2013 08:07AM
Thank you very much for the information I suspect your diagnosis about the buffer is correct.

I searched the documentation and couldn't find any reference for P1, what does this do?

I managed to upgrade the firmwhere (although it's almost new so I suspect it didn't need it) and it's up and running again which is a big relief as I can carry on with my project.

I have managed to lock it up again since and the only way I can find to regain comunications is by reloading the firmware, is there any way of doing a reset? (Power down doesn't work)
Re: BV4221 Stopped Working
September 16, 2013 08:31AM
P is the prompt command P1 or P0 it is in the data sheet on page 10.

The only time that it 'should' lock up is when the slave holds the clock low or there is some other device holding either the clock or data low but disconnecting the slave should resume normal service.

There are a few commands that could stop the device from responding as normal such as changing the line end character, switching off the prompt or changing the ACK character. This could be happening in some hidden depths of your program, but if not and you can define the sequence of commands that stops it working then I will be happy to release a bug fix release.
Re: BV4221 Stopped Working
September 16, 2013 01:19PM
Thank you for you response. I need to do some more investigation.

Please could you just clarify if the P0 command has been issued for no prompt or the auto baud has been turned off, does it stay like that even after a power off reset?
Re: BV4221 Stopped Working
September 16, 2013 06:29PM
To set up the BV4221 for use in an automated system:
P0 - sets promt off
D - set to decimal (optional)
F - fix write settings to EEPROM so that this is now default
B115200 - fixed baud rate to 115200 at start up

I have some Python code that does this to emulate smbus on windows - still work inprogress but here it is:
Sorry, only registered users may post in this forum.

Click here to login