Copy 144 LED console for my school project


Closed Thread
Results 1 to 39 of 39

Hybrid View

  1. #1
    Join Date
    Aug 2003
    Posts
    985


    Did you find this post helpful? Yes | No

    Default

    So I understand you want to go ahead and convert it to C?
    (still not quite sure).
    If you get the Microchip C30 compiler student demo version, it is free,
    and there is not much limitation on it. Only the auto code optimisations are turned off.
    Unless you are already using one you are happy with.
    I can say though that it would be quite possible to do the same program with it.

  2. #2
    Join Date
    Feb 2007
    Location
    London UK
    Posts
    5


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Art View Post
    So I understand you want to go ahead and convert it to C?
    Not without your help Art, from what I read.

    To recap:

    He starts with: can you please send to me the program in C++ please....

    Then he asks for the program and it is explained to him that the project is in Picbasic, not C.

    Then he says: 'Haha - he didn't see the attached file' etc.

    Then he asks for a component list.

    Then he aks for a program but without the games - he just wants a message scroller.

    He then says he's already started this project - what he means by this is not explained.

    He then asks again if it can be converted to C. It is not stated whether he feels that someone else should supply him with the C code, or whether he simply wants an assurance that it can be done.

    After a few terse responses, quite justified in my opinion, he resorts to rudeness.

    He then says; 'i ask that because if he can convert it,... not mean to do it because NOT TO DO IT IN MY OWN...your wrong for that...'

    Which I take to mean can Art do it for him. Or at least he would like Art's help because he cannot do it on his own.

    After finding a C compiler he discovers the Picbasic source code will not work in a C compiler and says: 'maybe the language is different.'

    What a surprise.

    He now resorts to wheedling and says he knows we are here to help him.

    No. We are not here to help people program in C. We are here to help people program in PicBasic, hence the title of the forum.

    There must be many sine scrollers out there, some programmed in C. Find a C forum, and ask there.

    Don't go into a Mosque and ask if they have the Koran in Hebrew. Or a Synagogue and ask for the Torah in Arabic - it's inviting rude comments.

  3. #3
    Join Date
    Sep 2010
    Posts
    16


    Did you find this post helpful? Yes | No

    Smile Yup art..

    Quote Originally Posted by Art View Post
    So I understand you want to go ahead and convert it to C?
    (still not quite sure).
    If you get the Microchip C30 compiler student demo version, it is free,
    and there is not much limitation on it. Only the auto code optimisations are turned off.
    Unless you are already using one you are happy with.
    I can say though that it would be quite possible to do the same program with it.

    i want to convert it in C(C source code)...and i already run the program and load it in PIC by using .HEX but...i want to change something by using PIC C COMPILER...and to understand the flow of program in a way of that i know...

  4. #4


    Did you find this post helpful? Yes | No

    Angry This is why...

    Though I haven't "been on"' this site in months I get these email updates regarding threads. I haven't been on, or contributed, to this site for EXACTLY the reason shown in this thread. I figured it was better to stay away from this site than get into flame wars and what ultimately would have turned into me getting outright banned. So far, "Mackrakit" has been the only one to step up and say it outright (paraphrasing) "do some work".

    First, from my own perspective; after Art did what he did, I saw very few (if anyone) say "thank you" (no, I'm not going to comb through the whole thread looking for the exception). I saw lots of "you should have done it this way or that", but no one stepped up and presented what Art did. I volunteered to do the PCB layout, and did. Once posted (on my hosted domain) I saw hundreds of downloads. You would have thought JUST ONE PERSON would have said "thank you", but no one did. I didn't do it (nor did Art I'm guessing) for accolades, but damn, there isn't ONE person that learned something and would offer a simple "thanks". The ONLY TIME you hear from anyone is when they want something from you. So, so as not to have to pay more for the download traffic, I pulled the files. If you think this petty, tough, you post the files and pay for it. And no, I won't send you the files.

    Along the way there was the question "do I have to use the "18" instead of the "16"? Well, did you compare TFD sheets? No, you jump on here and ask someone else to do it for you.

    And then the transistor questions; for CRYING OUT LOAD, it's a FRAKING TRANSISTOR, being USED AS A SATURATED SWITCH. If you don't know what a SATURATED SWITCH is STOP NOW and GET A BASIC BOOK ON ELECTRONICS. Why are you even LOOKING at microcontroller projects? There are literally THOUSANDS of transistors that could
    be used here; but, because you have NEVER CRACKED a BOOK you wouldn't know that. You just find complete projects that "look like what you want" and then needle people to make changes until it does "what you want".

    And students, students ARE THE WORST! You are supposed to be learning, not copying. By starting your questions about the type of transistor to use simply proves you have not been paying the slightest bit of attention and most likely have been cheating your way through school. There is no way, no way at all that you could have arrived in a microcontroller class and have to do a project without using transistors first. I don't care where you live, it's not going to happen. I belong to a professional engineering consulting site and I'm sickened by the posts by students looking for pro's to "do their homework"; I've seen incrediably complex tasks posted as final exams and these guys want to pay a pro to do it for $100.00. No wonder so much junk is out there.
    And then you follow-up with "convert it to C (or whatever) for me. With the following mods, Change this, change that. AND, do it FAST because we've already commited this for our final project. I can't tell you how many times I've seen this over the years. And when someone calls you on it, you get nasty with them and tell them to mind their own business. Bull. I've seen this on other threads over the years; people asking unreasonable questions (do I HAVE to use a resistor with an LED?) and the incredible amount of replies for not using one. If you don't know what a diode is and how to use one why are you doing this. If you went to machining site and asked if you "had" to use a sharp tool you'd get all kinds of replies I'm sure. Go to a car site and ask if you "have" to use oil in your engine.

    And the crap from the "beginners" that ask these questions, and the others that jump to their defense "we're just learning and you're being unhelpful and mean" and follow-up with "you don't know everything". Well, here's the deal; I had to learn and I did it by reading, studying, building and testing. When I didn't understand something, I got a BOOK about whatever it was and learned about it.

    Forums started out as a place where if you got truly "stuck" others knowledgable about a subject you could ask others about the subject and get a different perspective. But at that point you didn't have to ask questions like "what is the power supply doing", "did you bypass the supply pins", "is the clock running","is the reset pin tied active". Now you get people that know NOTHING, NOTHING and jump in the middle. And then, if you ask a legitimate question you get every bozo answering ("did you tie the reset pin active, I did this once and it didn't work" - no kidding, huh).

    Back to the "students"; there are a TON of references out there about "converting" "BASIC" to "C". I've seen one in particular about converting PICBASIC to C (no, I won't go find the link for you). Frankly, I doubt you could do that anyway; I'm guessing you know as much aout C as you do about transistors.

    So flame, kick me off for being "mean" or "unhelpful"; I couldn't care less. I will leave you with this; I'll do your final project, exactly as you want, in any language you want, with PCB layout, production ready (as I REALLY think the whole "student" thing is a ruse) with a B.O.M (that's "Bill of materials", the parts you'll need), with a list of substitute components of 50 different manufacturer part numbers. At my consulting rates the PCB layout alone was worth $1500.00. I figure with code and all, $6000.00 should do it.
    Last edited by mtripoli; - 9th September 2010 at 02:51.

  5. #5
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Does the $6,000 include a working prototype?
    Dave
    Always wear safety glasses while programming.

  6. #6
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default

    I wish I could charge that amount of money for my consultancy too...

    May be I have to change country.

    Seriously now. Mtripoli has absolutely right on alsmost all the points. I do not like to the attitude of some members too.

    And would never agree on giving the food on the plate. So for these members the direction to find their food is my option.

    I know that these kind of posts for "give that", "do this for me", etc will never stop. People are trying to get the best for them with minimal labor. It is in our nature. Others do more work, others not.

    Ignore them who are not worth it and spend your time creatively instead of commending it about it. After all your time is precious and they will not read it!

    Ioannis

  7. #7


    Did you find this post helpful? Yes | No

    Talking Of course!

    Quote Originally Posted by mackrackit View Post
    Does the $6,000 include a working prototype?
    No "working prototypes"; actual production ready modules.

    $6000.00 might sound like alot but it includes the obvious aggravation factor that would be involved here.

    Because of the proliferation of the DIY "modules" and DIY PCB etc. there is this idea that designing electronics is cheap. It's not. Slapping together a few parts and calling it done is not a design. I won't go into it because frankly it would be a waste of time. I design products designed for millions of units per run. If I did things the way I see some around here do I wouldn't be a design consultant, I'd ask people every day "you want fries with that".

    The REAL problem here is that any human being has this inherent want to help others. I do too. However, when people start a thread with "I know nothing about electronics or this stuff" and then continue on with nonsense it can get under your skin real fast. Or, in this case jump on a Picbasic forum and ask for C code; come on, get real.

    I think there is a very simple solution to this kind of problem. I've seen it suggested before in one form or another and the suggestor gets slammed for it. There should be a test to gain entry to the site. If you can't pass a simple test on basic electronics then you should go somewhere else. Immediately "beginners" say "but I came here for help". I'm talking about the truly basic; ohms law, transistor switching, simple logic, an "increment x" program. I in fact happened upon an electronics site that had just this kind of "entrance exam". It was for high-end audio amp design. I took the test and failed. I only failed by a couple of questions, but the fact of the matter is the people that were members of that site could converse with each other on a level that they all knew what the other was talking about. If I wanted to join it was on me to go learn what the things are that I failed. This site is open to anyone with a computer. I stopped coming here because you had to weed through all the nonsense to find the posts from people that had something genuine to offer or the ones that knew what they are doing but need help. Frankly, it's too bad it's called the "PICBASIC" forum. It sheds a bad light on a very good product and the people that are genuinely interested in using it.

  8. #8
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,653


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mtripoli View Post
    Though I haven't "been on"' this site in months ....
    Hi, MTripoli

    As I fully do understand your point of view, as I am surprised by it's violence may I say INNOCENCE ...

    What you describe have been observed for years in many specialities , and of course in workplaces and universities.

    Some kind of Internet spread desease ??? ... may be ...

    Everyone ( not exactly everyone ... Thanks to god ! ) " copies and Pastes " , ask for Instructables, Videos and , of course a touch of customization ... just to be able to tell bar-friends " I DID IT " ... or pass their exams !!!

    One of our greatest actor ( Jean Gabin ) was saying, 40 years ago, in " Les tontons flingueurs " , famous comic film about papies ripping off :

    " Bloody stupid people dare to do anything ... thats also how one can recognize them. "
    ... yeah, your right, sad world.

    I gently would answer you ...

    As you are not paid in any way here ... you're not to answer any query ...

    Just keep in mind everything placed on the Web can be " stolen " ...
    Copyright ??? ... just a view of mind !!!


    Regards
    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  9. #9
    C_Beginner's Avatar
    C_Beginner Guest


    Did you find this post helpful? Yes | No

    Default The death of competency

    MTripoli is correct.

    I recall reading a paper not so long ago written by a UNI professor regarding his concerns with all of this. Copy & paste to do assignments. Where's the world headed?

    Anyhow here's a glimpse at some C code:

    Code:
    /*
       8-LED Knight Rider Scanner    
       MCU: PIC16f877a
       
       Requirements:
          1. Connect 8 leds to portC
          2. 1 x push button to RB1 with pull up resistor
          3. 4MHz XTAL
       
       Usage:
         Pressing the switch causes the leds to chase back & forth   
    */
    
    // Global scope variables
    char i = 0; // Direction of scan
    char j = 1; // Gen working var
    char k = 0; // Gen working var
    
    void main()
    {
      TRISA = 0x00;      // PortA as output
      TRISB = 0x02;      // RB1 to as input rest as out
      TRISC = 0x00;      // PortC as output
      TRISD = 0x00;      // PortD as output
      TRISE = 0x00;      // PortE as output
      PORTC = 0x00;     // Init port, all pins low
    
       // Infinite loop
       while(1)
       {
          if (PORTB == 0)        // Button pressed?
          {
    
             PORTC = j;            // Write to port
             delay_ms(100);      // 100mS delay
             
             // Scan dir forward //
    
             if (i == 0)
             {
                j = (j << 1);       // Shift bits left
             }
             
             // Scan backward //
    
             else
             {
                j = (j >> 1);    // Shift right
             }
    
             // Toggle direction //
    
             k ++;                   // Inc counter
             
             if (k == 7)           // Counter reached n val?
             {
                k = 0;              // Reset
                i = ~i;             // Toggle dir
             }
          }
       }
    }
    Not much more involved than BASIC. The help file in MikroC is great, if that fails then go and buy a book. If that fails too, then go and do some formal study.

  10. #10


    Did you find this post helpful? Yes | No

    Wink

    Quote Originally Posted by Acetronics View Post
    Hi, MTripoli

    As I fully do understand your point of view, as I am surprised by it's violence may I say INNOCENCE ...
    "Violence" may not be the correct translation (I see you are from France - God I love the food there; I 've spent some time in Pau at Elf Aquitane many years ago. The Pyrenees mountains are stunningly beautiful). How about "frankness" or "forthrightness" (franchise?).

    Quote Originally Posted by Acetronics View Post
    As you are not paid in any way here ... you're not to answer any query ...
    Alain
    I wasn't answering any query. I was stating my opinion.

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts