Forum Replies Created
-
AuthorPosts
-
Michael
KeymasterYou can’t use anything requiring interrupts with the video experimenter. So, you can’t use Serial (use the pollserial implementation that is part of TVout). How does the RTC library work? If it uses interrupts, then the precise timing needed by TVout is going to interfere.
Basically it takes all of the Arduino’s capability to generate a video signal, so interfacing with other complex hardware is always going to be very challenging or impossible.
Michael
KeymasterInstead of passing a function to set the flag, just pass a function that performs the communication. So when you enter VBI, your function gets called and you do the work.
void readSensor() {
// read sensor
}
tv.set_vbi_hook(&readSensor);Michael
KeymasterBasically, generating a video signal consumes almost the entire CPU of the Arduino and requires very precise timing. It’s hard to use something like I2C at the same time you are generating a video signal.
If you look closely at the TVout library, there is the ability to attach a function to run during the vertical blanking interval (VBI). Look at this project where I used a Wii nunchuck (I2C) with TVout. http://nootropicdesign.com/projectlab/2011/03/20/tv-blaster/
It uses my Hackvision controllers library which has a stripped down, simplified I2C implementation that uses less memory. Maybe your sensor will work with simpler I2C implementation.
Michael
KeymasterIt’s not just one line of code. You need to keep track of which wire you expect to be cut next. If you are not experienced with coding, this may be challenging.
I get so many requests for code changes to the clock, that I have now started charging customers for this service. It takes time. I can’t develop software for everyone for free.
http://nootropicdesign.com/store/index.php?main_page=product_info&cPath=5&products_id=33Michael
KeymasterSo you want to defuse the device by disconnecting the wires in this order: 3, 2, 1? Or 1,2,3? You are being very confusing by using the word “after”. Do you mean WIRE_1 THEN WIRE_2 THEN WIRE_3?
When you say WIRE_1 AFTER WIRE_2 AFTER WIRE_3 that means WIRE_3 is first, then WIRE_2, then WIRE_1.
You need to be clear!
Michael
KeymasterI don’t know if English is your first language, but your posts are completely unreadable. This sentence makes absolutely no sense:
so I would like to know what you want to write to be in sequence
If you want help, you need to type complete, coherent sentences. If you are asking other people to stop what they are doing and give you their attention and time, then show some respect by making some effort yourself and describe your problems in clear language. If you won’t take the time to do that, then don’t expect others to take the time to do your project for you.
Michael
KeymasterYes, you can modify the code to defuse the clock with that order of wire cutting. Modify the function called [tt:hrtz0oqd]countdown()[/tt:hrtz0oqd]. This function defines the wires for defuse and detonate. Just write logic to ensure the wires are cut in the order you want.
The Arduino source code for the clock is available on this page: https://nootropicdesign.com/defusableclock/hack.htmlMichael
KeymasterThis is an advanced project because it can be difficult to find the closed caption data. I’m not sure that closed caption data uses the same format in Brazil as it does in the US.
I suggest you carefully follow the procedures in the article
http://nootropicdesign.com/projectlab/2011/03/20/decoding-closed-captioning/Are you able to see the CC data bytes displayed on the screen? They should be flashing bars near the top. Uncomment the call to [tt:3twt510c]displayBitPositions()[/tt:3twt510c] to help you align the values in the array [tt:3twt510c]bpos[/tt:3twt510c] to line up with the data bits. This is tricky, so you need to spend time studying the project article.
Michael
KeymasterThanks so much for that feedback! I’m glad you are having FUN.
Michael
KeymasterI don’t understand what you are asking. What are you trying to do with the Defusable Clock? Program it using an Arduino? If you want to program it, you need a USB to serial adapter or cable. See http://nootropicdesign.com/defusableclock/hack.html
If you want help from others, you really should ask your questions more clearly.Michael
KeymasterThe largest value for an int is 32767, so you need to use a “long”. That is why the counter only goes up to 32 seconds.
Michael
KeymasterHave you looked at the code available here: http://nootropicdesign.com/defusableclock/hack.html
It is not difficult to modify the code. To change the countdown duration, just change the declaration of COUNTDOWN_DURATION.
To change the pins for detonate/defuse, change these lines at the beginning of the function countdown():
// assign random pins
defusePin = random(WIRE_1, (WIRE_4+1));
detPin = defusePin;
while (detPin == defusePin) {
detPin = random(WIRE_1, (WIRE_4+1));
}For no randomness, you could just assign them:
defusePin = WIRE_2;
detPin = WIRE_3;Michael
KeymasterI’m sorry, there’s not much I can do. I don’t know what GPS module you are using, how you wired everything, etc. I did that GPS project years ago, so I can’t guarantee that everything will always work — it is just a project I did. If the hardware you bought from me works, then that’s good. But I have thousands of customers, and am a one man company, so I can’t get involved deeply into everyone’s projects. That’s just the reality.
If you want to post more details with schematics, hardware specs, code etc. then maybe others on this forum can help, but so far you haven’t provided any of that, other than to say “it doesn’t work”. How would you help someone with a complex project if they just said “it doesn’t work”?
You said you were a beginner with Arduino — this is NOT a beginner project. It is complex.
Michael
KeymasterThe code I made available on my project here: https://nootropicdesign.com/projectlab/2011/05/20/overlay-gps-on-video/
Compiles cleanly in Arduino 1.0.4. I don’t know why you are having a compilation problem. Are you using Arduino 1.0.4?
-
AuthorPosts