Skip to content

Instantly share code, notes, and snippets.

View tomvictor's full-sized avatar
🎯
Focusing

Tom Victor tomvictor

🎯
Focusing
View GitHub Profile
@tomvictor
tomvictor / auto-complete-django-view.py
Last active October 4, 2017 14:05
auto-complete-django-view
def serchView(request):
query = request.GET.get("query")
print(query)
# queryset_list = super(PostListAPIView, self).get_queryset(*args, **kwargs)
queryset_list = Tutorial.objects.all() # filter(user=self.request.user)
if query:
queryset_list = queryset_list.filter(
Q(title__icontains=query) |
Q(content__icontains=query)
).distinct()
@tomvictor
tomvictor / transmitter.c
Created November 18, 2015 05:45
cc2500
// Author Tomvictor
// [email protected]
// buildfromzero.com
// this code is only an demo for simple RF communication
// make suitable changes for your appication
// For full code visit https://github.com/Tomvictor/CC2500
#include "include.h"
#include <msp430.h>
#include "lcd.h"
#include "lcd1.h"