Offline
Sr. Member
Karma: 0
Posts: 451
I am a amateur.
|
 |
« on: May 15, 2012, 05:48:49 pm » |
1) When the number "B10101010", or "0xaa" is shifted out LSBFIRST to a 74HC595 8-bit shift register, pin Q7's state is: a) LOW (connected to GND) b) completely unconnected 2) What is the state of pin Q7' of the 74HC595 when the same number is shifted out? 3) True or false: you can access the characters of a String by treating it as an array like this: String a = "lol"; char b = a[1]; in Arduino. 4) Can you print this to the Serial Monitor: 鐵路華工紀念碑 ? 5) What is the ASCII number of this character: 鐵 6) How does pin Q7' relate to pin Q7? 7) Name the short lead of an LED.  Name the long lead of an LED. 9) Direct current flows from: a) From ground up to V+ b) From V+ to ground c) Any way it wants A correct answer is worth 10 points. A wrong answer is worth 1 point. An indirect answer is worth 2 points. An unanswered question is worth 0 points. Who will win? Note: more questions can be posted before day of answer release without notice. Answers will be released on 2012/05/20.
|
|
|
|
« Last Edit: May 19, 2012, 03:12:58 pm by dkl65 »
|
Logged
|
|
|
|
|
|
|
|
|
Netherlands
Online
Tesla Member
Karma: 87
Posts: 9386
In theory there is no difference between theory and practice, however in practice there are many...
|
 |
« Reply #3 on: May 16, 2012, 12:36:23 pm » |
1) When the number "B10101010", or "0xaa" is shifted out LSBFIRST to a 74HC595 8-bit shift register, pin Q7's state is: a) LOW (connected to GND) b) completely unconnected Does a 74HC595 has a Q7 pin? 2) What is the state of pin Q7' of the 74HC595 when the same number is shifted out? Same 3) True or false: you can access the characters of a String by treating it as an array like this: String a = "lol"; char b = a[1]; Depends on the programming language  4) no I cannot, - by definition the right answer ! 5) It looks more like a miniturized QR code to me? 6) Brother and sister? Think it is too difficult for me ... 
|
|
|
|
|
Logged
|
|
|
|
|
CO, USA
Offline
God Member
Karma: 4
Posts: 706
|
 |
« Reply #4 on: May 16, 2012, 07:14:41 pm » |
4) Can you print this to the Serial Monitor: 鐵路華工紀念碑 ?
Any string is just a series of bytes. (or bits, if you want to think of it that way) So, yes, you can find a way to store such a string in a C++ constant or variable, and send it to the serial monitor. However, whether the serial monitor will display it correctly is another matter.
7) Name the short lead of an LED.
Mini-Me
8 ) Name the long lead of an LED.
Harold
9) Direct current flows from: a) From ground up to V+ b) From V+ to ground c) Any way it wants
Electron, or hole current?
More questions to come (maybe)!
What is your name? What is your quest? What is your favourite color? 
|
|
|
|
|
Logged
|
... it is poor civic hygiene to install technologies that could someday facilitate a police state. -- Bruce Schneier
|
|
|
|
Offline
Sr. Member
Karma: 0
Posts: 451
I am a amateur.
|
 |
« Reply #5 on: May 16, 2012, 07:48:21 pm » |
My name is dkl65. My quest is to become the best Pokemon Trainer. My favorite color is blue. Who else wants to take a shot at the questions?
|
|
|
|
|
Logged
|
|
|
|
|
Austin, TX
Online
Faraday Member
Karma: 41
Posts: 5165
CMiYC
|
 |
« Reply #6 on: May 19, 2012, 02:35:52 pm » |
These questions really aren't defined well enough to answer. In most of them I think I know the answer you are after, but the (lack of) wording makes it difficult to be sure. 1) When the number "B10101010", or "0xaa" is shifted out LSBFIRST to a 74HC595 8-bit shift register, pin Q7's state is: a) LOW (connected to GND) b) completely unconnected What is "shifted out." Does this imply that SRCLK and and RCLK remain unchanged? "Shifting out" a data pattern from one device isn't the same as "shifting in" a pattern from another. For example, if clock was never toggled and only SER (Pin 14) was toggled, then Q7 remains unchanged. 2) What is the state of pin Q7' of the 74HC595 when the same number is shifted out? Again, depends on how the clocks are being used and definition of "shifted out". Assuming the clocks were not toggled, I would expect Q'7/Q'H (aka serial out, depending on the manufacturer of the chip) to remain unchanged. 3) True or false: you can access the characters of a String by treating it as an array like this: String a = "lol"; char b = a[1]; in Arduino. True 4) Can you print this to the Serial Monitor: 鐵路華工紀念碑 ? No 5) What is the ASCII number of this character: 鐵 There isn't one, it isn't an ASCII Character. It is Unicode. 6) How does pin Q7' relate to pin Q7? Pin Q7' of What? 7) Name the short lead of an LED.
8) Name the long lead of an LED. What about surface mount LEDs? Perhaps you meant Negative (Cathode) and Positive (Anode) sides of a through-hole LED? 9) Direct current flows from: a) From ground up to V+ b) From V+ to ground c) Any way it wants[/quote] Based on Conventional or Electron Flow?
|
|
|
|
|
Logged
|
|
|
|
|
Offline
Sr. Member
Karma: 0
Posts: 451
I am a amateur.
|
 |
« Reply #7 on: May 20, 2012, 09:35:20 am » |
Answers released on 2012/05/20 10:35 AM EDT: 1) b) completely unconnected. It can also be called "high impendance". Code used: void updateLEDs(int value){ digitalWrite(latch, LOW); //Pulls the chips latch low shiftOut(data, clock, LSBFIRST, value); //Shifts out the 8 bits to the shift register digitalWrite(latch, HIGH); //Pulls the latch high displaying the data } 2) about 2.11V 3) True. 4) No. Instead, it prints “éµè•¯è¯å•¥ç´å¿µç” 5) Trick question! It is not an ASCII character. 6) They don't have any relation. 7) Cathode. 8 ) Anode. 9) a) from ground up to V+. V+ is positively charged, and ground is neutral. V+ will pull electrons toward it. "Current is often regarded as flowing from + to -; a legacy of ancient misunderstandings". Scores: James C4S: 38 johnwasser: 35 robtillaart: 14 justjed: 6
|
|
|
|
« Last Edit: May 20, 2012, 09:39:06 am by dkl65 »
|
Logged
|
|
|
|
|
CO, USA
Offline
God Member
Karma: 4
Posts: 706
|
 |
« Reply #8 on: May 20, 2012, 10:23:12 am » |
4) No. Instead, it prints “é�µè•¯è�¯å•¥ç´€å¿µç” Scores: justjed: 6
Actually, if you read the question again, it asks, "Can you print this to the Serial Monitor ...?". Obviously, you can, as demonstrated by the quoted output. That the software doesn't correctly display it as ideograms in the correct codepage is immaterial, as the question didn't contain that as a criterion. Had it asked, "Can you print this correctly IN the Serial Montor", that would be different. 7 and 8 aren't, technically, questions. Taking 'Name' as 'give a name to', I did. Therefore, my score is at least 32. Of course, you can argue that I'm being needlessly pedantic, and in reality, I just thought I'd have some fun with it. Those test questions make assumptions, presumably supplied by the context of the class in which they're being asked, but we here don't know what those are. And English is terribly imprecise. Of course, I don't expect most instructors to have much of a sense of humor about this, and count yourself fortunate if you find one who does. 
|
|
|
|
|
Logged
|
... it is poor civic hygiene to install technologies that could someday facilitate a police state. -- Bruce Schneier
|
|
|
|
Global Moderator
UK
Offline
Brattain Member
Karma: 137
Posts: 19007
I don't think you connected the grounds, Dave.
|
 |
« Reply #9 on: May 20, 2012, 10:28:23 am » |
It can also be called "high impendance". BZZZZT.
|
|
|
|
|
Logged
|
Pete, it's a fool looks for logic in the chambers of the human heart.
|
|
|
|
Offline
Sr. Member
Karma: 0
Posts: 451
I am a amateur.
|
 |
« Reply #10 on: May 20, 2012, 10:36:37 am » |
7 and 8 aren't, technically, questions. Taking 'Name' as 'give a name to', I did. Yes, you did. But you named them incorrectly; that is worth 1 point each. Of course, you can argue that I'm being needlessly pedantic If that means that you are trying to find faults within the question, and argue that you are correct, then you are being "needlessly pendantic". You are interpreting the questions in an alternate, incorrect way, which some people love to do. The Serial monitor cannot write Chinese. But I can.
|
|
|
|
« Last Edit: May 20, 2012, 10:49:07 am by dkl65 »
|
Logged
|
|
|
|
|
Austin, TX
Online
Faraday Member
Karma: 41
Posts: 5165
CMiYC
|
 |
« Reply #11 on: May 20, 2012, 10:46:12 am » |
You are interpreting the questions in an alternate, incorrect way, which some people love to do..
This demonstrates the reason why precision is needed when asking engineering questions. For example, your first question would have been significantly more clear if you had included the code you posted with the answer. Of course, a schematic along with it would have been ideal... Just like when people coming here asking questions about their projects.
|
|
|
|
|
Logged
|
|
|
|
|
CO, USA
Offline
God Member
Karma: 4
Posts: 706
|
 |
« Reply #12 on: May 20, 2012, 11:15:15 am » |
You are interpreting the questions in an alternate, incorrect way, which some people love to do.
The alternate way isn't incorrect. And, while I admit to a predilection for narrowness in language usage, particularly in technical environments, there's more too it than that. For example, if you rely on manufacturers always following a particular standard when producing LEDs, you will eventually find yourself with a non-working circuit. See LED polarity. As someone who sometimes has difficulty learning certain electronic things, due to prior misunderstandings arising from either overly-simplified or poorly written explanations, I also hope to help you avoid the same pitfall. There's an adage which is perhaps useful: "The good thing about standards is that there are so many to choose from". I hope that when you encounter an LED which doesn't follow the short/long convention, you will not be surprised. Maybe it would be too pretentious, but see also Koan. (And don't forget the 'having fun' part either.) 
|
|
|
|
|
Logged
|
... it is poor civic hygiene to install technologies that could someday facilitate a police state. -- Bruce Schneier
|
|
|
|
Global Moderator
UK
Offline
Brattain Member
Karma: 137
Posts: 19007
I don't think you connected the grounds, Dave.
|
 |
« Reply #13 on: May 20, 2012, 11:22:01 am » |
"needlessly pendantic". In engineering, that's what we call an oxymoron.
|
|
|
|
|
Logged
|
Pete, it's a fool looks for logic in the chambers of the human heart.
|
|
|
|
|