Would you use SmartNotes CE when I finish it?
Yes
 33%  [ 7 ]
No
 19%  [ 4 ]
If you finish...
 47%  [ 10 ]
Total Votes : 21

This post is outdated Very Happy .
See the latest progress of SmartNotes here: https://www.cemetech.net/forum/viewtopic.php?p=305280#305280
View the Github repository here: https://github.com/randomguy70/smartNotesRewrite
Download the latest build here: https://github.com/randomguy70/smartNotesRewrite/releases/tag/v0.1
Here is the Github Repo: https://github.com/randomguy70/SmartNotesCE
I have only been coding in C for a few weeks, so please please tell me if I should format anything differently, or if I am making any n00b mistakes!
Thank you in advance!
I was asked about getting GetCSC scan codes using keypadc, so here you go:
Code:
uint8_t get_single_key_pressed(void) {
    static uint8_t last_key;
    uint8_t only_key = 0;
    kb_Scan();
    for (uint8_t key = 1, group = 7; group; --group) {
        for (uint8_t mask = 1; mask; mask <<= 1, ++key) {
            if (kb_Data[group] & mask) {
                if (only_key) {
                    last_key = 0;
                    return 0;
                } else {
                    only_key = key;
                }
            }
        }
    }
    if (only_key == last_key) {
        return 0;
    }
    last_key = only_key;
    return only_key;
}
progress update: i gave up on using appvar text data files, and am using some simple hexadecimal character arrays instead. now the input text function works. this is the first time in a while I have been able to work on this at all Smile.
Congrats Smile, on finishing the input routine.
Okay, so apparently this code is not working; it is supposed to copy the pointers to the names of every txt appvar to an array of string pointers.

Code:

uint8_t loadFileNames(char **buffer) {
   uint8_t numFiles = 0;
   char *namePtr;
   void *search_pos = NULL;

   while ((namePtr = ti_Detect(&search_pos, "TXT")) != NULL) {
      uint8_t i = 0;
      while(namePtr[i]!='\0'){
         buffer[numFiles][i] = namePtr[i];
         i++;
      }
      numFiles++;
   }
   return numFiles;
}

char fileNames[20][9] = {0};
loadFileNames(fileNames);

thank you in advance1 Very Happy

Edit:
Jacobly helped me to fix it.
are there any good monospace fonts that anybody would like to recommend? I think I will use monospace for this project because it would make my life a lot easier!😆
FiraCode is an awesome monospace font. You should definitely try using it.
does this string copying function work? I have issues with my code, so I am not sure if this is it.

Code:

char* strcopy(char* dest, const char* src) {
   uint8_t strPos = 0;
   while(src[strPos]!= '\0') {
      dest[strPos] = src[strPos];
      strPos++;
   }
   if(!strPos) {
      return NULL;
   } else {
      return dest;
   }
}

following mateo's wise advice, i am now using strcpy
Why aren't you just using strcpy.
Well, I haven't had too much time to work on this recently, but I fixed the fileScrolling bugs, added file renaming, added and refined colors in my palette, cleaned up a ton of code, and created several sprites (which I haven't implemented yet). There are still several minor bugs which I will fix shortly, and then I will move on to opening files and displaying their actual text.
Well, in the past few days I added sprites, updated the gui graphics considerably, and am now going to start working on an extra menu for the home screen.
Here is the link to the main branch of the repo: https://github.com/randomguy70/SmartNotesCE
Here is the link to the working branch of the repo which I update more often: https://github.com/randomguy70/SmartNotesCE/tree/working_branch
randomguy wrote:
Well, in the past few days I added sprites, updated the gui graphics considerably, and am now going to start working on an extra menu for the home screen.

This is looking really great! I think the sprites definitely make it look better, and I love the stripey "Notecard" background. Keep up the great work!
Alright, so I am trying to implement file hiding right now, but my code seems to reset the RAM.

Code:

int toggleHiddenStatus(char* name) {
   ti_var_t fileSlot = ti_Open(name, "r");
   if(!fileSlot || strlen(name) > 8) {
      ti_Close(fileSlot);
      return -1;
   }
   
   char temp[9] = {0};
   ti_GetName(temp, fileSlot);
   temp[0] ^= 64;
   ti_Close(fileSlot);
   ti_Rename(name, temp);
   
   return true;
   // return isHidden(temp);
}

Thank you in advance!
How does this compare to CEedit?
arusher999 wrote:
How does this compare to CEedit?

They're different editors for different purposes.
SmartNotes is, well, a notepad. CEdit is a general text editor.
Nice work on all this! Kind of inspires me to work on my BasicNote update again.
Michael2_3B wrote:
Nice work on all this! Kind of inspires me to work on my BasicNote update again.

Oh no. Laughing
Howdy! It's been a super long time since I've been able to get any serious work done on SmartNotes but here's my progress:

My new repository: https://github.com/randomguy70/smartNotesRewrite

Implemented:
- Complete rewrite for readability and efficiency
- Split buffer for instant insertion/deletion
- File creation
- File naming up to 16 characters long
- File deletion
- File hiding / un-hiding
- Working menu system (I haven't added all the menus I want yet though)
- Display file text
- Scrolling through a file's text

To do:
- Add text insertion / deletion
- Add lots of cool menus
- Find some slick, modern sprites
- Add settings
- Add a palette editor (will be very easy to implement from the way I have set up my colors)
- Alphabetically organize files (perhaps some veteran has ideas on the most efficient route to do this?)
- Add custom fonts
- Add word wrap option in settings (word wrap functionality is almost complete)
- Add file encryption
- Add login pin (pin will be used to decrypt files)
- Anything you guys suggest in the forum!!!


*Note: my current build automatically generates a lot of testing files at runtime



Stay tuned for my first release!
Really nice progress!

Implementing Insertion/deletion is really going to take this to the next level, great stuff.

(Also I noticed you got rid of the notepad background?)
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 2
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement